<template>
	<div class="components-container">
        <div class="header-form">
            <div class="layui-inline">
                <label class="layui-form-label">部门名称</label>
                 <div class="layui-input-inline">
                <el-input v-model="selectData.DptNameLike" placeholder="请输入部门名称"></el-input>
                 </div>
            </div>
            <div class="layui-inline">
                <label class="layui-form-label">管理员姓名</label>
                 <div class="layui-input-inline">
                <el-input v-model="selectData.NameLike" placeholder="请输入管理员姓名"></el-input>
                 </div>
            </div>
            <el-button type="primary" @click="btnSearch">搜索</el-button>
            <el-button @click="btnRepeat" >重置</el-button>
        </div>
         <!--数据列表-->
        <dataTable :headList="headList" :dataList="dataList" :hiddenColumn="false" :pageOrder="pageOrder" @pageChange="pageChange"></dataTable>
	</div>

</template>
<style rel="stylesheet/scss" lang="scss" scoped>
@import "src/styles/common.scss";
</style>
<script>
import apiBase from "@/api/apiBase.js";
import dataTable from "@/components/Table/DataTable";
import { manage } from "@/mixins/managePage.js";
export default {
  name: "administratorInfo",
  mixins: [manage],
  data() {
    return {
      selectData:{},
    };
  },
  methods: {
    getData() {
      let Data = JSON.parse(JSON.stringify(this.selectData));
      var data = {
        PageIndex: this.pageOrder.currentPage,
        PageSize: this.pageOrder.pageSize,
        OrderBy: this.pageOrder.orderType,
        OrderByType: this.pageOrder.orderSort,
        Data: Data
      };
      apiBase.DoService(data, apiBase.getApiAdress().Login.GetSystemUser, res => {
        this.dataList = res.data.content.OutData;
        this.pageOrder.totalNum = res.data.content.RecordCount;
      });
    },
    btnSearch() {
      this.getData();
    },
    btnRepeat() {
      this.selectData = {};
      this.getData();
    }
  },
  mounted() {},

  components: {
    dataTable
  },
  created() {
    this.getData();
    this.headList = [
      {
        ColumnAlign:"center",
        ColumnKey:"USRNAME",
        ColumnName:"用户姓名",
        ColumnOrder:"USRNAME",
      },
      {
        ColumnAlign:"center",
        ColumnKey:"Phone",
        ColumnName:"联系电话",
        ColumnOrder:"Phone",
      },
      {
        ColumnAlign:"center",
        ColumnKey:"DPTNAME",
        ColumnName:"部门名称",
        ColumnOrder:"DPTNAME",
      },
    ]
  }
};
</script>